home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 30
/
Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso
/
Aminet
/
dev
/
lang
/
SmallEiffel.lha
/
SmallEiffel
/
bin_c
/
short3.c
< prev
next >
Wrap
C/C++ Source or Header
|
1998-12-22
|
4KB
|
339 lines
/*
-- ANSI C code generated by :
-- SmallEiffel The GNU Eiffel Compiler -- Release (- 0.79) --
-- Copyright (C), 1994-98 - LORIA - UHP - CRIN - INRIA - FRANCE --
-- Dominique COLNET and Suzanne COLLIN - colnet@loria.fr --
-- http://www.loria.fr/SmallEiffel --
*/
#include "short.h"
T250 r250realloc(T250 C,T2 a1,T2 a2){
T250 R=NULL;
R=calloc(a2,sizeof(T0*));
r250copy_from(R,C,(a1)-(1));
return R;
}
void r250set_all_with(T250 C,T0* a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=(a1);
_i=(_i)-(1);
}
}
void r250copy_from(T250 C,T250 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T191 r191realloc(T191 C,T2 a1,T2 a2){
T191 R=NULL;
R=calloc(a2,sizeof(T0*));
r191copy_from(R,C,(a1)-(1));
return R;
}
void r191clear_all(T191 C,T2 a1){
T2 _i=0;
T0* _v=NULL;
_i=a1;
while (!((_i)<(0))) {
(C)[_i]=(_v);
_i=(_i)-(1);
}
}
void r191set_all_with(T191 C,T0* a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=(a1);
_i=(_i)-(1);
}
}
void r191copy_from(T191 C,T191 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T45 r45realloc(T45 C,T2 a1,T2 a2){
T45 R=NULL;
R=calloc(a2,sizeof(T0*));
r45copy_from(R,C,(a1)-(1));
return R;
}
void r45copy_from(T45 C,T45 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T84 r84realloc(T84 C,T2 a1,T2 a2){
T84 R=NULL;
R=calloc(a2,sizeof(T0*));
r84copy_from(R,C,(a1)-(1));
return R;
}
void r84copy_from(T84 C,T84 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T174 r174realloc(T174 C,T2 a1,T2 a2){
T174 R=NULL;
R=calloc(a2,sizeof(T0*));
r174copy_from(R,C,(a1)-(1));
return R;
}
void r174set_all_with(T174 C,T0* a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=(a1);
_i=(_i)-(1);
}
}
void r174copy_from(T174 C,T174 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T313 r313realloc(T313 C,T2 a1,T2 a2){
T313 R=NULL;
R=calloc(a2,sizeof(T0*));
r313copy_from(R,C,(a1)-(1));
return R;
}
void r313set_all_with(T313 C,T0* a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=(a1);
_i=(_i)-(1);
}
}
T2 r313fast_index_of(T313 C,T0* a1,T2 a2){
T2 R=0;
while (!(((R)>(a2))||((a1)==((void*)((C)[R]))))) {
R=(R)+(1);
}
return R;
}
void r313move(T313 C,T2 a1,T2 a2,T2 a3){
T2 _i=0;
/*[IF*/
if((a3)==(0)){
}
else if((a3)<(0)){
_i=a1;
while (!((_i)>(a2))) {
(C)[(_i)+(a3)]=((C)[_i]);
_i=(_i)+(1);
}
}
else{
_i=a2;
while (!((_i)<(a1))) {
(C)[(_i)+(a3)]=((C)[_i]);
_i=(_i)-(1);
}
}
/*FI]*/
}
void r313clear(T313 C,T2 a1,T2 a2){
T2 _i=0;
T0* _v=NULL;
_i=a1;
while (!((_i)>(a2))) {
(C)[_i]=(_v);
_i=(_i)+(1);
}
}
void r313copy_from(T313 C,T313 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T305 r305realloc(T305 C,T2 a1,T2 a2){
T305 R=NULL;
R=calloc(a2,sizeof(T0*));
r305copy_from(R,C,(a1)-(1));
return R;
}
void r305copy_from(T305 C,T305 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T295 r295realloc(T295 C,T2 a1,T2 a2){
T295 R=NULL;
R=calloc(a2,sizeof(T0*));
r295copy_from(R,C,(a1)-(1));
return R;
}
void r295copy_from(T295 C,T295 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T212 r212realloc(T212 C,T2 a1,T2 a2){
T212 R=NULL;
R=calloc(a2,sizeof(T0*));
r212copy_from(R,C,(a1)-(1));
return R;
}
void r212clear_all(T212 C,T2 a1){
T2 _i=0;
T0* _v=NULL;
_i=a1;
while (!((_i)<(0))) {
(C)[_i]=(_v);
_i=(_i)-(1);
}
}
void r212copy_from(T212 C,T212 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T27 r27realloc(T27 C,T2 a1,T2 a2){
T27 R=NULL;
R=calloc(a2,sizeof(T0*));
r27copy_from(R,C,(a1)-(1));
return R;
}
void r27set_all_with(T27 C,T0* a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=(a1);
_i=(_i)-(1);
}
}
T6 r27equal_like(T0* a1,T0* a2){
T6 R=0;
/*[IF*/
/*AF*//*AF*/if((a1)==((void*)(a2))){
R=1;
}
else if(((a1)==((void*)(NULL)))||((a2)==((void*)(NULL)))){
}
else{
R=r7is_equal(((T7*)a1),a2);
}
/*FI]*/
return R;
}
T2 r27fast_index_of(T27 C,T0* a1,T2 a2){
T2 R=0;
while (!(((R)>(a2))||((a1)==((void*)((C)[R]))))) {
R=(R)+(1);
}
return R;
}
void r27copy_from(T27 C,T27 a1,T2 a2){
T2 _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T2 r27index_of(T27 C,T0* a1,T2 a2){
T2 R=0;
while (!(((R)>(a2))||(r27equal_like(a1,(C)[R])))) {
R=(R)+(1);
}
return R;
}